package com.learn.controller;

import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;


@RestController
@RequestMapping("test")
public class TestController {
    @GetMapping("/post")
    @PreAuthorize("hasAnyAuthority('select')")
    public String postMethodName() {
        return "Hello World!";
    }
    
}
